

function addSensorbitCod(Blockly) {




    //舵机模块
  Blockly.Python.microbit_servo = function(block) {
    var dropdown_servoPort = this.getFieldValue('servoPort');
    var dropdown_servoAngle = Blockly.Python.valueToCode(this, 'servoAngle', Blockly.Python.ORDER_ATOMIC);
    Blockly.Python.definitions_['import_microbit'] = 'from microbit import *';
    Blockly.Python.definitions_['import_Relay'] = 'from actuator import servo';
    var code = "servo.angle("+ dropdown_servoPort + ", " + dropdown_servoAngle +")\n";
    return code;
  }

    return Blockly;
}

module.exports = addSensorbitCod;

